import abbrs

OUTPUT_PATH = r'G:\Users\01\Documents\Projects\training-dashboard\data\latest.json'
LOG_PATH = '../yedu-log'

def main():
	import os
	dat = []
	for i in os.listdir(LOG_PATH):
		if '.json' not in i: continue
		print(i)
		d = abbrs.load_json(os.path.join(LOG_PATH, i))
		for record in d: record[0] = ''
		dat.extend(d)
	abbrs.dump_json(OUTPUT_PATH, dat)

if __name__ == '__main__':
	main()